<!DOCTYPE html>
<html lang="en" style="background:#f5f5f5">
<head>
    <meta charset="UTF-8">
    <title>正方教务系统验证码识别</title>
    <link rel="stylesheet" href="../static/css/uikit.min.css"/>
    <link rel="stylesheet" href="../static/css/form-file.css"/>
    <link rel="stylesheet" href="../static/css/upload.css"/>
    <script src="../static/js/jquery.min.js"></script>
    <script src="../static/js/uikit.min.js"></script>
    <script src="../static/js/upload.js"></script>
</head>
<body>

<div class="tm-grid-truncate uk-text-center">

    <div class="uk-grid">
        <div class="uk-width-1-1">
            <div class="uk-panel uk-panel-box">
                <div class="uk-panel uk-panel-box uk-text-center uk-text-bold uk-text-large">正方验证码识别</div>
            </div>
        </div>
        <div class="uk-width-1-1 ">
            <div class="uk-panel uk-panel-box uk-width-medium-1-3 uk-container-center">
                <form class="uk-form" method="post" enctype="multipart/form-data"
                      action="http://localhost:5000/searchByPic">
                    <div class="uk-form-row">
                        {% if res %}<input type="text" placeholder="识别结果"
                                           value="{{res}}" disabled></div>
                    {% else %}
                    <input type="text" placeholder="识别结果" disabled>{% endif %}

                    <br><br>
                    <div class="uk-form-file" style="margin-right:5px">
                        <button class="uk-button">验证码图片</button>
                        <input type="file" id="upload-select" name="img">
                    </div>
                    <input type="submit" class="uk-button uk-button-success" value="识别"></input>
                </form>
                <br>


            </div>
        </div>
        <div class="uk-container uk-width-1-1 ">

        <h3>接口介绍</h3>

        <div class="uk-grid uk-grid-match" data-uk-grid-margin="">

            <div class="uk-width-medium-1-2 uk-row-first">
                <h4>POST接口</h4>
                <div class="uk-panel">
                    <p>接口地址：<a href="#">http://119.29.133.130:5000/searchByPic</a></p>
                    <p>方法：POST</p>
                    <p>参数：验证码文件，input的type属性为file,name属性为img</p>
                    <p>参数：参数名为 interface，值为True，表示为接口调用，否则会返回html模板</p>
                    <p>注意事项：form元素要设置enctype属性为"multipart/form-data"</p>
                </div>
            </div>
            <div class="uk-width-medium-1-2">
                <h4>GET接口</h4>
                <div class="uk-panel">
                    <p>接口地址：<a href="#">http://119.29.133.130:5000/search</a></p>
                    <p>方法：GET</p>
                    <p>参数：参数名为 base64str url安全方式编码的base64字符串</p>
                    <p>注意事项：url安全方式编码参考链接：<a href="http://blog.csdn.net/mr_raptor/article/details/50806657">Link</a></p>
                </div>
            </div>
        </div>

    </div>
    <br><br><br><br>
    <div class="uk-container uk-width-1-1 "><a
            href="https://gitee.com/iss2015302580016/ZhengFangJiaoWuXiTongYanZhengMaShiBie"
            class="uk-icon-hover uk-icon-github">项目git地址</a></div>

    </div>

</div>
</body>
</html>